import request from '@/utils/request'
import {praseStrEmpty} from "@/utils/ruoyi";


export function listStore(query) {
  return request({
    url: '/inventory/store/list',
    method: 'get',
    params: query
  })
}


export function addStore(query) {
  return request({
    url: '/inventory/store/add',
    method: 'POST',
    data: query
  })
}


export function updateStore(query) {
  return request({
    url: '/inventory/store/update',
    method: 'POST',
    data: query
  })
}


export function infoStore(query) {
  return request({
    url: '/inventory/store/info',
    method: 'GET',
    params: {
      id: query
    }
  })
}


export function delStore(storeIds) {
  return request({
    url: '/inventory/store/' + storeIds,
    method: 'GET'
  })
}


export function changeStoreStatus(id, status) {
  let data = {
    id: id,
    status: status
  }
  return request({
    url: '/inventory/store/changeStatus',
    method: 'POST',
    data: data
  })
}
